<?php

namespace App\Observers;

use App\Models\Config;

class ConfigObserver
{
    public function saving(Config $config)
    {
    	$usage = $config->user_usage;
    	$usage = preg_replace('/ width="(\d+)"/i', '', $usage);
    	$usage = preg_replace('/ height="(\d+)"/i', '', $usage);
    	$config->user_usage = $usage;
    }
}
